#include <stdlib.h> 
#include <time.h> 

#include <fstream>
#include <string>

#include <sstream>
#include <iostream>

#include <vector>

using namespace std;
const int maxArraySize = 2000;

class GraphCreator 
{
public: 
	int nodeCount;
	int edgeCount;
	vector<int> vert;
	GraphCreator(int seed)
	{
		srand(seed);
		nodeCount = rand() % maxArraySize; 
		edgeCount = 0;
		generateGraph(nodeCount);	
	}

	void generateGraph(int nodeNumber)
	{
		int nodes = nodeNumber;
		
		for(int i = 0; i < nodes; i++)
		{
			vert.push_back(i);
		}

		ofstream myfile;
		myfile.open ("output.txt");

		for(int i = 0; i < vert.size(); i++)
		{
			int edges = rand() % 10 + 0; 
			edgeCount += edges;
			for(int j = 0; j < edges;j++)
			{
				myfile <<  i << "\t" << vert[rand() % vert.size()] << endl;
			}
		}
		
		 myfile.close();
	}
};		




